import Vue from 'vue'
import Router from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
import login from '@/view/login'
import demo from '@/view/demo'
import dataList from '@/view/dataList'

Vue.use(Router)

export default new Router({
  mode: 'history', //切换路径模式，变成history模式
  routes: [
    {
      path: '/login',
      name: 'login',
      component: login
    } ,
    {
      path: '/',
      name: 'demo',
      component: demo
    },
     {
      path: '/dataList',
      name: 'dataList',
      component: dataList
    }
  ]
})
